import cv2 as cv
from nn import MtcnnV2, load_model
import mxnet as mx
from utils import plot_bbox
# from ipdb import set_trace
# set_trace()

mtcnn = MtcnnV2(load_model('pnet', 'models/mtcnn/pnet/032.params'))
image = cv.imread('data/test.jpg', cv.IMREAD_COLOR)
image = cv.cvtColor(image, cv.COLOR_BGR2RGB)
bbox = mtcnn.detect(image)
print(bbox.shape)
print(bbox[:5])
plot_bbox(image, bbox)
